import { Curves, CurveAnimation, lerp } from '../list/route'
import { clamp } from '../list/utils'

const { screenWidth } = wx.getSystemInfoSync()

Component({
  properties: {
    index: {
      type: Number,
      value: -1,
    },
    url: {
      type: String,
      value: '',
    },
    content: {
      type: String,
      value: '',
    },
    nickname: {
      type: String,
      value: '',
    }
  },
  data: {
    swiperHeight: 0,
    imageList: []
  },

    attached() {
      //图片比例
      this.setData({
        swiperHeight: screenWidth 
      }),
      console.log("!!!!!!!!!!")
      console.log(this.data.ratio)

      wx.request({
        url: `http://192.168.43.252:8081/api/admin/photos?current=1&size=18&albumId=${this.data.nickname}&isDelete=0`,
        method:'GET',
        success:(res)=>{
          console.log(res)
          console.log(res.data.data.recordList)
          this.setData({
            imageList : res.data.data.recordList
          })
          console.log(this.data.imageList)
        },

      })
    },




})

